<!doctype html>
<html>
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <style>
        *{
            margin: 0;
            padding: 0;
        }
        #wrap{
            position:relative;
            width: 400px;
            height: 400px;
            border: 1px solid skyblue;
        }
        #wrap .menu{
            position: absolute;
            top:50%;
            left: 50%;
            margin-top: -100px;
            margin-left: -100px;
            width: 200px;
            height: 200px;
            background-color: pink;
            border-radius: 50%;
            text-align: center;
            line-height: 200px;
            transition: 0.5s;
            cursor: pointer;
        }
        #wrap .child{
            position: absolute;
            top: 150px;
            left: 150px;
            width: 100px;
            height: 100px;
            background-color: orangered;
            border-radius: 50%;
            text-align: center;
            line-height: 100px;
            transform: scale(0);
            transition: 0.5s;
        }
        #wrap.show .menu{
            opacity: 0;
        }

        #wrap.show .child.b1{
            transform: scale(1) translate(-150px,-150px);
        }
        #wrap.show .child.b2{
            transform:scale(1) translate(150px,-150px);
        }
        #wrap.show .child.b3{
            transform:scale(1) translate(-150px,150px);
        }
        #wrap.show .child.b4{
           transform:scale(1) translate(150px,150px);
        }
    </style>
</head>
<body>
<div id = "wrap">
    <div class = "menu">菜单</div>

    <div class = "child b1">首页</div>
    <div class = "child b2">文章</div>
    <div class = "child b3">登录</div>
    <div class = "child b4">注册</div>
</div>
<script>
    let menu = document.querySelector("#wrap .menu")
    let wrap = document.querySelector("#wrap")
    menu.onclick = function (){
        wrap.classList.add("show")//本质上先写好整个父级盒子wrap的样式，给它添加一个show的隐藏样式，一旦点击则切换成show的样式
    }
</script>
</body>
</html>